home *** CD-ROM | disk | FTP | other *** search
/ The Games Machine 76 / XENIATGM66.iso / Indiana Jones / Indiana Jones.exe / RESOURCE / PREVIEW.GOB / cog_olv_drainwater.cog < prev    next >
Text File  |  1999-11-15  |  16KB  |  648 lines

  1. # Jones 3D Cog Script
  2. #
  3. # olv_drainwater.cog
  4. #
  5. # Cog to drain water from pool.
  6. #
  7. # [DS & revised by HB]
  8. #
  9. # (C) 1999 LucasArts Entertainment Company LLC. All Rights Reserved
  10. #
  11. # ==============================================================================
  12.  
  13. symbols
  14.  
  15.     message        startup    
  16.     message        activated
  17.     message        entered
  18.     message        exited
  19.     message        pulse
  20.     
  21.     keyframe    in_activate=in_activate_medium.key        local
  22.     
  23.     sound        fallsnd=gen_waterfall_a.wav                local
  24.     sound        mouthstop=gen_stone_stop_c.wav            local
  25.     sound        blowsnd=olv_waterfall_blast_c.wav        local
  26.     sound        waterdrn=nub_bull_move1_c.wav                local
  27.     sound        underwtr=gen_underwater_a.wav            local
  28.     sound        hitstone=pru_boulder_crash_c.wav            local
  29.     sound        music0=mus_teo_statuerise.wav                local
  30.  
  31.     thing        raingod                            nolink
  32.     thing        mouth
  33.     thing        fallpos                                    nolink
  34.     thing        splashpos
  35.     thing        splashpos2
  36.     thing        splashpos3
  37.     thing        splashpos4
  38.     thing        switch0
  39.     thing        head0
  40.     thing        rockcam                                    nolink
  41.     thing        campos1                                    nolink
  42.     thing        camtarg                                    nolink
  43.     thing        switch_cam                                nolink
  44.     thing        ghostsurf
  45.     thing        surf                                    local
  46.  
  47.     thing        waterfall                                local
  48.     thing        fallsplash                                local
  49.     thing        fallsplash2                                local
  50.  
  51.  
  52.     surface        watersurf0
  53.     surface        watersurf1
  54.     surface        watersurf2
  55.     surface        watersurf3
  56.     surface        watersurf4
  57.     surface        watersurf5
  58.     surface        watersurf6
  59.     surface        watersurf7
  60.     surface        watersurf8
  61.     surface        headslot                                  mask=0x080
  62.     surface        climb0
  63.     surface        climb1
  64.     surface        climb2
  65.  
  66.  
  67.  
  68.     sector      pool0
  69.     sector        pool1
  70.     sector      pool2
  71.     sector        pool3
  72.     sector      pool4
  73.     sector        pool5
  74.     sector      pool6
  75.     sector        pool7
  76.     sector      pool8
  77.     sector        pool9
  78.     sector      pool0s
  79.     sector        pool1s
  80.     sector      pool2s
  81.     sector        pool3s
  82.     sector      pool4s
  83.     sector        pool5s
  84.     sector      pool6s
  85.     sector        pool7s
  86.     sector      pool8s
  87.     sector        pool9s
  88.     sector      pool0sm
  89.     sector        pool1sm
  90.     sector      pool2sm
  91.     sector        pool3sm
  92.     sector      pool4sm
  93.     sector        pool5sm
  94.     sector      pool6sm
  95.     sector        pool7sm
  96.     sector      pool8sm
  97.     sector        pool9sm
  98.  
  99.     sector        pool0sn
  100.     sector        pool1sn
  101.     sector        pool2sn
  102.  
  103.  
  104.     cog          bridgecog                                # send message to set bridge (olv_bridge_pad)
  105.     cog        hints                                    # send message when complete. 
  106.  
  107.     template    watersurf=h2odrain                        local
  108.     template    falltemp=waterfall                        local
  109.     template    falltemplong=longwaterfall                    local
  110.     template    splashtemp=fallfoam_3x5b                    local
  111.  
  112.     vector        waterlight                                local
  113.     vector        drylight                                local
  114.     vector        dryshade                                local
  115.     vector        shademore                                local
  116.  
  117.     flex        fps=9.0        desc=playback_speed
  118.     
  119.     int            drained=0                                 local
  120.     int            blocked=0                                local
  121.     int            blocked=0                                local
  122.     int            curcam                                local
  123.     int            cnt0=0                                local
  124.     int            cnt1=0                                local
  125.     int            cntw                                    local
  126.     int            fallsound                                local
  127.     int            vibe                                    local
  128.     int            shake                                    local
  129.  
  130. # ........new anim stuff........
  131.  
  132.     thing        ghostpour
  133.     thing        ghostspray
  134.     thing        bridgelook
  135.     sector    outfallsec0
  136.     sector    outfallsec1
  137.     surface    outerfall0
  138.     surface    outerfall1
  139.     template    waterpour
  140.     template    waterspray
  141.     material    animmat0=olv_a4sprite_pour.mat    local
  142.     material    animmat1=olv_a4sprite_spray.mat    local
  143.  
  144.     flex        cameraview                local
  145.     flex        cameraend                local
  146.     flex        rockcamera                local
  147.     int        drainwtr                local
  148.     int        outfallsnd                local
  149.     thing        pouring                local
  150.     thing        spraying                local
  151.     vector    posoffset                local
  152.     vector    angoffset                local
  153.  
  154. # ---- Head no-move stuff ---------
  155.     keyframe    nopush=in_pushpull_anticipate.key    local
  156.     thing        player                    local
  157.     int        on_top=0                    local
  158.     int        solved=0                    local
  159.     int        talkin                    local
  160.     sound        nope=inxj098.wav                local    #It won't budge.
  161.  
  162. end
  163.  
  164. # ------------------------------------------------------------------------------
  165.  
  166. code
  167.  
  168. # ..............................................................................
  169.  
  170. startup:
  171.  
  172.     sleep(0.01);
  173.     player = GetLocalPlayerThing();
  174.     SetThingLight(raingod, '0.5 0.5 0.4', 0.6, 0.01);
  175.     SetThingLight(mouth, '0.5 0.5 0.4', 0.6, 0.01);
  176.     waterlight = VectorSet(0.0, 0.6, 0.8);
  177.     drylight = VectorSet(0.4, 0.4, 0.3);
  178.     dryshade = VectorSet(0.2, 0.2, 0.1);
  179.     shademore = VectorSet(0.15, 0.15, 0.1);
  180.     waterfall = Creatething(falltemp, fallpos);
  181.     CaptureThing(waterfall);
  182.     fallsound =    PlaySoundThing(fallsnd, fallpos, 1, 5, 25, 1);
  183.     fallsplash= Creatething(splashtemp, splashpos);
  184.     fallsplash2= Creatething(splashtemp, splashpos2);
  185.     CaptureThing(fallsplash);
  186.     CaptureThing(fallsplash2);
  187.  
  188.  
  189.  
  190.     SetFaceGeoMode(outerfall0, 0);
  191.     SetFaceGeoMode(outerfall1, 0);
  192.     ClearSurfaceFlags(climb0, 0x2000);            #Not Climbable.
  193.     ClearSurfaceFlags(climb1, 0x2000);            #Not Climbable.
  194.     ClearSurfaceFlags(climb2, 0x2000);            #Not Climbable.
  195.     for (cnt0 = 0; cnt0<=9; cnt0=cnt0+1)
  196.     {
  197.         SetSectorFlags(pool0[cnt0], 2);
  198.         SetSectorFlags(pool0s[cnt0], 2);
  199.         SetSectorFlags(pool0sm[cnt0], 2);
  200.         SectorSound(pool0[cnt0], underwtr, 1);
  201.         SectorSound(pool0s[cnt0], underwtr, 1);
  202.         SectorSound(pool0sm[cnt0], underwtr, 1);
  203.     }
  204.     for (cnt1 = 0; cnt1<=3; cnt1=cnt1+1)
  205.     {
  206.         SetSectorFlags(pool0sn[cnt1], 2);
  207.         SectorSound(pool0sn[cnt1], underwtr, 1);
  208.     }
  209.     return;
  210.  
  211. # ..............................................................................
  212.  
  213. activated:
  214.  
  215.     if ((getsenderref() == head0) && (solved == 1))
  216.     {
  217.     if(on_top == 1) return;
  218.     on_top=1;
  219.     MakeMeStop();
  220.     DeselectWeaponWait(player);
  221.     StartCutscene(0);
  222.     PlayKey(player, nopush, 4, 0x12, 1);
  223.     talkin = PlayVoice(player, nope, 1.0, 1);
  224.     WaitForSound(talkin);
  225.     EndCutscene();
  226.     on_top=0;
  227.     ClearActorFlags(player, 0x200000);
  228.     return;
  229.     }
  230.  
  231.     if (getsenderref() == switch0)
  232.     {
  233.     curcam = GetCurrentCamera();
  234.     MakeMeStop();
  235.     DeselectWeaponWait(player);
  236.     StartCutscene(1);
  237.  
  238.     if (drained==0)
  239.     {
  240.         SendMessageEx(hints, user2, 1, 0, 0, 0);    #param0=1; Water Drained.
  241.         SetExtCamOffsetToThing(switch_cam);
  242.         SetExtCamLookOffsetToThing(switch0);
  243.         PlayKey(player, in_activate, 4, 0x12, 0);
  244.         Movetoframe(switch0, 1, 1.0);
  245.         waitforstop(switch0);
  246.         drained=1;
  247.  
  248.         for (cntw = 0; cntw<=8; cntw=cntw+1)
  249.         {
  250.             SetFaceGeoMode(watersurf0[cntw], 0);
  251.         }
  252.  
  253.         SetAdjoinFlags(watersurf8, 2);        #skullface.
  254.  
  255.         for (cnt0 = 0; cnt0<=9; cnt0=cnt0+1)
  256.         {
  257.             ClearSectorFlags(pool0[cnt0], 2);
  258.             ClearSectorFlags(pool0s[cnt0], 2);
  259.             ClearSectorFlags(pool0sm[cnt0], 2);
  260.             SectorSound(pool0[cnt0], -1, 1);
  261.             SectorSound(pool0s[cnt0], -1, 1);
  262.             SectorSound(pool0sm[cnt0], -1, 1);
  263.             Setsectorlight(pool0[cnt0], drylight, .1);
  264.             Setsectorlight(pool0s[cnt0], dryshade, .1);
  265.             Setsectorlight(pool0sm[cnt0], shademore, .1);
  266.         }
  267.         for (cnt1 = 0; cnt1<=3; cnt1=cnt1+1)
  268.         {
  269.             ClearSectorFlags(pool0sn[cnt1], 2);
  270.             SectorSound(pool0sn[cnt1], -1, 1);
  271.             Setsectorlight(pool0sn[cnt1], shademore, .1);
  272.         }
  273.  
  274.  
  275.         call cameraview;
  276.  
  277.         return;
  278.     }
  279.     else
  280.     {
  281.         SetExtCamOffsetToThing(switch_cam);
  282.         SetExtCamLookOffsetToThing(switch0);
  283.         PlayKey(Player, in_activate, 4, 0x12, 0);
  284.         Movetoframe(switch0, 1, 1.0);
  285.         waitforstop(switch0);
  286.         drained=0;
  287.         call cameraview;
  288.  
  289.         return;
  290.     }
  291.  
  292.     return;
  293.     }
  294.  
  295.  
  296. # ..............................................................................
  297.  
  298. entered:
  299.  
  300.     if (getsenderref() == head0)
  301.     {
  302.         on_top=1;
  303.         return;
  304.     }
  305.  
  306.     if((getsenderref() == headslot) && (getsourceref() == head0))
  307.     {
  308.         blocked=1;
  309.         # print ("block in slot");
  310.     }
  311.  
  312.     return;
  313.  
  314. # ..............................................................................
  315.  
  316. exited:
  317.  
  318.     if (getsenderref() == head0)
  319.     {
  320.         on_top=0;
  321.         return;
  322.     }
  323.  
  324.     if((getsenderref() == headslot) && (getsourceref() == head0))
  325.     {
  326.         blocked=0;
  327.         # print ("block removed from slot");
  328.     }
  329.  
  330.     return;
  331.     
  332. # ..............................................................................
  333.  
  334. cameraview:
  335.  
  336.     # Let's see what happened...
  337.     Sleep(1.0);
  338.     SetCameraLookInterp(2, 0);
  339.     SetCameraPosInterp(2, 0);
  340.     SetCameraFocus(2, campos1);
  341.     SetCameraSecondaryFocus(2, camtarg);
  342.     SetCurrentCamera(2);
  343.     SetCameraFOV(70, 0, 0.0);
  344.     
  345.     if (drained == 1)
  346.     {
  347.         # Close Tlaloc's mouth...
  348.         Movetoframe(mouth, 1, 1.0);
  349.  
  350.         # Pinch off waterfall...
  351.         ThingFadeAnim(waterfall, 1.0, 0.0, 1.0, 0);
  352.         Sleep(1.0);
  353.         Destroything(waterfall);
  354.         StopSound(fallsound, 0);
  355.         Destroything(fallsplash);
  356.         Destroything(fallsplash2);
  357.  
  358.         SetSurfaceFlags(climb0, 0x2000);            #Climbable.
  359.         SetSurfaceFlags(climb1, 0x2000);            #Climbable.
  360.         SetSurfaceFlags(climb2, 0x2000);            #Climbable.
  361.     }
  362.     else
  363.     {
  364.         if (blocked == 1)
  365.         {
  366.             PlaySoundLocal(music0, 1.0, 0.0, 0x0, 0);        
  367.         }
  368.  
  369.         Movetoframe(mouth, 0, 1.0);
  370.         waterfall = Creatething(falltemplong, fallpos);
  371.         CaptureThing(waterfall);
  372.         SetThingAlpha(waterfall, 0.0);
  373.         ThingFadeAnim(waterfall, 0.0, 1.0, 1.0, 0);
  374.         fallsound =    PlaySoundThing(fallsnd, fallpos, 1, 5, 25, 1);
  375.  
  376.         ClearSurfaceFlags(climb0, 0x2000);            #Not Climbable.
  377.         ClearSurfaceFlags(climb1, 0x2000);            #Not Climbable.
  378.         ClearSurfaceFlags(climb2, 0x2000);            #Not Climbable.
  379.     }
  380.  
  381.     WaitForStop(mouth);
  382.     PlaySoundThing(mouthstop, mouth, 1, 5, 10, 0);
  383.     Sleep(1.0);
  384.     MoveToFrame(camtarg, 1, 3.87);
  385.     MoveToFrame(campos1, 1, 3.0);
  386.     SetCameraFOV(60, 1, 4);
  387.  
  388.     # Let's handle the water...
  389.     # print ("oh thats what it does");
  390.  
  391.     if (drained == 1)
  392.     {
  393.         # Water draining...
  394.         surf = Creatething(watersurf, ghostsurf);
  395.         capturething(surf);
  396.         SetThingLight(surf, '0.0 0.3 0.4', 0.6, 0.01);
  397.         SetCollideType(surf, 0);
  398.         # print ("water going to empty");
  399.         Movetoframe(surf, 1, 0.5);
  400.         drainwtr =     PlaySoundLocal(waterdrn, 1.0, 0.0, 1, 0);
  401.         #        PlaySoundThing(waterdrn, surf, 1.0, 15, 45, 1);
  402.         WaitForStop(surf);
  403.         StopSound(drainwtr, 0);
  404.         DestroyThing(surf);
  405.         call cameraend;
  406.     }
  407.     else
  408.     {
  409.         # Water filling...
  410.         fallsplash= Creatething(splashtemp, splashpos3);
  411.         fallsplash2= Creatething(splashtemp, splashpos4);
  412.         CaptureThing(fallsplash);
  413.         CaptureThing(fallsplash2);
  414.         surf = Creatething(watersurf, ghostsurf);
  415.         capturething(surf);
  416.     #    AttachThingToThing(fallsplash, surf);
  417.     #    AttachThingToThing(fallsplash2, surf);
  418.  
  419.         SetThingLight(surf, '0.0 0.3 0.4', 0.6, 0.01);
  420.         SetCollideType(surf, 0);
  421.         # print ("water going to fill");
  422.         Jumptoframe(surf, 1, pool0);
  423.         Movetoframe(surf, 0, 0.5);
  424.         drainwtr =     PlaySoundLocal(waterdrn, 1.0, 0.0, 1, 0);
  425.         #        PlaySoundThing(waterdrn, surf, 1.0, 15, 45, 1);
  426.         WaitForStop(surf);
  427.         StopSound(drainwtr, 0);
  428.         DestroyThing(surf);
  429.         DestroyThing(fallsplash);
  430.         DestroyThing(fallsplash2);
  431.  
  432.         fallsplash= Creatething(splashtemp, splashpos);
  433.         fallsplash2= Creatething(splashtemp, splashpos2);
  434.         CaptureThing(fallsplash);
  435.         CaptureThing(fallsplash2);
  436.  
  437.         for (cntw = 0; cntw<=8; cntw=cntw+1)
  438.         {
  439.             SetFaceGeoMode(watersurf0[cntw], 4);
  440.         }
  441.         ClearAdjoinFlags(watersurf8, 2);        # skullface
  442.  
  443.         for (cnt0 = 0; cnt0<=9; cnt0=cnt0+1)
  444.         {
  445.             SetSectorFlags(pool0[cnt0], 2);
  446.             SetSectorFlags(pool0s[cnt0], 2);
  447.             SetSectorFlags(pool0sm[cnt0], 2);
  448.             SectorSound(pool0[cnt0], underwtr, 1);
  449.             SectorSound(pool0s[cnt0], underwtr, 1);
  450.             SectorSound(pool0sm[cnt0], underwtr, 1);
  451.             Setsectorlight(pool0[cnt0], waterlight, .1);
  452.             Setsectorlight(pool0s[cnt0], waterlight, .1);
  453.             Setsectorlight(pool0sm[cnt0], waterlight, .1);
  454.         }
  455.         for (cnt1 = 0; cnt1<=3; cnt1=cnt1+1)
  456.         {
  457.             SetSectorFlags(pool0sn[cnt1], 2);
  458.             SectorSound(pool0sn[cnt1], underwtr, 1);
  459.             Setsectorlight(pool0sn[cnt1], waterlight, .1);
  460.         }
  461.  
  462.         if (blocked == 1)
  463.         {
  464.             blocked=0;
  465.             call rockcamera; # was goto
  466.             return;
  467.         }
  468.         DestroyThing(waterfall);
  469.         waterfall = Creatething(falltemp, fallpos);
  470.         CaptureThing(waterfall);
  471.         call cameraend;
  472.     }
  473.  
  474.     return;
  475.  
  476. # ..............................................................................
  477.  
  478. cameraend:
  479.     ResetCameraFOV(0, 0.0);
  480.     SetCurrentCamera(curcam);
  481.     ClearActorFlags(Player, 0x200000);
  482.     Movetoframe(switch0, 0, 1.0);
  483.     RestoreExtCam();
  484.     EndCutscene();
  485.     MoveToFrame(camtarg, 0, 10);
  486.     MoveToFrame(campos1, 0, 10);
  487.     return;
  488.  
  489. # ..............................................................................
  490.  
  491. rockcamera:
  492.  
  493.     # Let's look outside now...
  494.     SetFaceGeoMode(outerfall0, 4);
  495.     SetFaceGeoMode(outerfall1, 4);
  496.     Setsectorlight(outfallsec0, waterlight, .1);
  497.     Setsectorlight(outfallsec1, waterlight, .1);
  498.     outfallsnd = PlaySoundThing(fallsnd, ghostpour, 1, 5, 25, 1);
  499.     SetCameraLookInterp(2, 0);
  500.     SetCameraPosInterp(2, 0);
  501.     SetCameraFocus(2, rockcam);
  502.     SetCameraSecondaryFocus(2, head0);
  503.     SetCurrentCamera(2);
  504.     CaptureThing(head0);    
  505.     PlaySoundThing(blowsnd, head0, 1, 30, 50, 0);
  506.     SetCameraFOV(20, 0, 0);
  507.     Sleep(0.01);
  508.     SetCameraFOV(45, 1, 1.5);
  509.     pouring = CreateThing(waterpour, ghostpour);
  510.     spraying = CreateThing(waterspray, ghostspray);
  511.     materialanim(animmat0, fps, 0);
  512.     materialanim(animmat1, fps, 0);
  513.     MoveToFrame(head0, 1, 0);
  514.     MoveToFrame(head0, 2, 10);
  515.     WaitForStop(head0);
  516.     PlaySoundLocal(hitstone, 1.0, 0.0, 0, 0);
  517.     
  518.     # Need to make head non-pushable.
  519.     solved=1;
  520.     ClearThingFlags(head0, 0x40000000);
  521.  
  522.     shake = 3;
  523.     SetPulse(0.1);
  524.     Sleep(0.5);
  525.     shake = 2;
  526.     Sleep(0.5);
  527.     SetPulse(0.0);
  528.  
  529.     DestroyThing(pouring);
  530.     DestroyThing(spraying);
  531.     SendMessage(bridgecog, user1);
  532.     SendMessageEx(hints, user2, 2, 0, 0, 0);    #param0=2; Rock head valley.
  533.     Sleep(0.2);
  534.     SetCameraFOV(60, 1, 2.0);
  535.     SetCameraLookInterp(2, 1);
  536.     SetCameraInterpSpeed(2, 2.0);
  537.     Sleep(0.1);
  538.     SetCameraSecondaryFocus(2, bridgelook);
  539.     Sleep(5.0);
  540.     
  541.     SetCameraLookInterp(2, 0); # reset default
  542.     SetCameraInterpSpeed(2, 1.0); # reset default
  543.     SetFaceGeoMode(outerfall0, 0);
  544.     SetFaceGeoMode(outerfall1, 0);
  545.     Setsectorlight(outfallsec0, drylight, .1);
  546.     Setsectorlight(outfallsec1, drylight, .1);
  547.     stopsound(outfallsnd, 0);
  548.     call cameraend;
  549.     return;
  550.  
  551. # ..............................................................................
  552.  
  553. pulse:
  554.  
  555.     vibe = RandBetween(1, 4);
  556.     if (vibe == 1)
  557.     {
  558.         if (shake == 1)
  559.         {
  560.             posOffset = '-0.005 0.00 -0.001'; #1 was .005x
  561.             angOffset = '0.00 -0.001 0.001';
  562.         }
  563.         if (shake == 2)
  564.         {
  565.             posOffset = '0.01 -0.01 0.005'; #2
  566.             angOffset = '0.005 0.00 -0.005';
  567.         }
  568.         if (shake == 3)
  569.         {
  570.             posOffset = '0.01 0.02 -0.02'; #3
  571.             angOffset = '-0.01 0.01 -0.01';
  572.         }
  573.     }
  574.     if (vibe == 2)
  575.     {
  576.         if (shake == 1)
  577.         {
  578.             posOffset = '0.005 -0.002 0.001'; #2 was .005x
  579.             angOffset = '0.001 0.00 -0.001';
  580.         }
  581.         if (shake == 2)
  582.         {
  583.             posOffset = '0.005 0.01 -0.01'; #3
  584.             angOffset = '-0.005 0.005 -0.00';
  585.         }
  586.         if (shake == 3)
  587.         {
  588.             posOffset = '-0.02 0.00 0.02'; #4 was .01x
  589.             angOffset = '0.00 0.00 0.01';
  590.         }
  591.     }
  592.     if (vibe == 3)
  593.     {
  594.         if (shake == 1)
  595.         {
  596.             posOffset = '0.002 0.002 -0.002'; #3 was .002x
  597.             angOffset = '-0.001 0.002 -0.002';
  598.         }
  599.         if (shake == 2)
  600.         {
  601.             posOffset = '-0.015 0.00 0.01'; #4 was .01x
  602.             angOffset = '0.00 0.00 0.01';
  603.         }
  604.         if (shake == 3)
  605.         {
  606.             posOffset = '-0.025 0.00 -0.01'; #1 was .02x
  607.             angOffset = '0.00 -0.01 0.01';
  608.         }
  609.     }
  610.     if (vibe == 4)
  611.     {
  612.         if (shake == 1)
  613.         {
  614.             posOffset = '-0.001 0.00 0.002'; #4
  615.             angOffset = '0.00 0.00 0.001';
  616.         }
  617.         if (shake == 2)
  618.         {
  619.             posOffset = '-0.01 0.00 -0.005'; #1
  620.             angOffset = '0.00 -0.005 0.005';
  621.         }
  622.         if (shake == 3)
  623.         {
  624.             posOffset = '0.02 -0.02 0.01'; #2
  625.             angOffset = '0.01 0.00 -0.01';
  626.         }
  627.     }
  628.  
  629.     vibe = RandBetween(1, 3);
  630.     if (vibe == 1)
  631.     {
  632.         SetPulse(0.05);
  633.     }
  634.     if (vibe == 2)
  635.     {
  636.         SetPulse(0.1);
  637.     }
  638.     if (vibe == 3)
  639.     {
  640.         SetPulse(0.15);
  641.     }
  642.  
  643.     SetPOVShake(posOffSet, angOffSet, 200.0, 200.0);
  644.  
  645.     return;
  646.  
  647. end
  648.